package com.lmax.disruptor.custom.group;

import com.lmax.disruptor.EventHandler;
import com.lmax.disruptor.custom.demo.Trade;

public class Handler5 implements EventHandler<Trade>
{

    private String name = "handler5";

    public void onEvent(final Trade trade) throws Exception
    {
//        System.out.println("handler5 set add price:");
        trade.setPrice(trade.getPrice() + 3);
    }

    @Override
    public void onEvent(final Trade arg0, final long seq, final boolean arg2) throws Exception
    {
        System.out.println("---" + name + "----" + seq);
        this.onEvent(arg0);
    }

}
